Optimal. Leaf size=104 \[ \frac{2 A \sqrt{\cos (c+d x)} \text{EllipticF}\left (\frac{1}{2} (c+d x),2\right ) \sqrt{b \sec (c+d x)}}{d}+\frac{2 B \sin (c+d x) \sqrt{b \sec (c+d x)}}{d}-\frac{2 b B E\left (\left .\frac{1}{2} (c+d x)\right |2\right )}{d \sqrt{\cos (c+d x)} \sqrt{b \sec (c+d x)}} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.0822444, antiderivative size = 104, normalized size of antiderivative = 1., number of steps used = 6, number of rules used = 5, integrand size = 23, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.217, Rules used = {3787, 3771, 2641, 3768, 2639} \[ \frac{2 A \sqrt{\cos (c+d x)} F\left (\left .\frac{1}{2} (c+d x)\right |2\right ) \sqrt{b \sec (c+d x)}}{d}+\frac{2 B \sin (c+d x) \sqrt{b \sec (c+d x)}}{d}-\frac{2 b B E\left (\left .\frac{1}{2} (c+d x)\right |2\right )}{d \sqrt{\cos (c+d x)} \sqrt{b \sec (c+d x)}} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 3787
Rule 3771
Rule 2641
Rule 3768
Rule 2639
Rubi steps
\begin{align*} \int \sqrt{b \sec (c+d x)} (A+B \sec (c+d x)) \, dx &=A \int \sqrt{b \sec (c+d x)} \, dx+\frac{B \int (b \sec (c+d x))^{3/2} \, dx}{b}\\ &=\frac{2 B \sqrt{b \sec (c+d x)} \sin (c+d x)}{d}-(b B) \int \frac{1}{\sqrt{b \sec (c+d x)}} \, dx+\left (A \sqrt{\cos (c+d x)} \sqrt{b \sec (c+d x)}\right ) \int \frac{1}{\sqrt{\cos (c+d x)}} \, dx\\ &=\frac{2 A \sqrt{\cos (c+d x)} F\left (\left .\frac{1}{2} (c+d x)\right |2\right ) \sqrt{b \sec (c+d x)}}{d}+\frac{2 B \sqrt{b \sec (c+d x)} \sin (c+d x)}{d}-\frac{(b B) \int \sqrt{\cos (c+d x)} \, dx}{\sqrt{\cos (c+d x)} \sqrt{b \sec (c+d x)}}\\ &=-\frac{2 b B E\left (\left .\frac{1}{2} (c+d x)\right |2\right )}{d \sqrt{\cos (c+d x)} \sqrt{b \sec (c+d x)}}+\frac{2 A \sqrt{\cos (c+d x)} F\left (\left .\frac{1}{2} (c+d x)\right |2\right ) \sqrt{b \sec (c+d x)}}{d}+\frac{2 B \sqrt{b \sec (c+d x)} \sin (c+d x)}{d}\\ \end{align*}
Mathematica [A] time = 0.119837, size = 73, normalized size = 0.7 \[ \frac{2 \sqrt{b \sec (c+d x)} \left (A \sqrt{\cos (c+d x)} \text{EllipticF}\left (\frac{1}{2} (c+d x),2\right )+B \sin (c+d x)-B \sqrt{\cos (c+d x)} E\left (\left .\frac{1}{2} (c+d x)\right |2\right )\right )}{d} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [C] time = 0.287, size = 453, normalized size = 4.4 \begin{align*} 2\,{\frac{ \left ( \cos \left ( dx+c \right ) +1 \right ) ^{2} \left ( -1+\cos \left ( dx+c \right ) \right ) ^{2}}{d \left ( \sin \left ( dx+c \right ) \right ) ^{5}}\sqrt{{\frac{b}{\cos \left ( dx+c \right ) }}} \left ( iA{\it EllipticF} \left ({\frac{i \left ( -1+\cos \left ( dx+c \right ) \right ) }{\sin \left ( dx+c \right ) }},i \right ) \cos \left ( dx+c \right ) \sqrt{ \left ( \cos \left ( dx+c \right ) +1 \right ) ^{-1}}\sqrt{{\frac{\cos \left ( dx+c \right ) }{\cos \left ( dx+c \right ) +1}}}\sin \left ( dx+c \right ) -iB\cos \left ( dx+c \right ) \sqrt{ \left ( \cos \left ( dx+c \right ) +1 \right ) ^{-1}}\sqrt{{\frac{\cos \left ( dx+c \right ) }{\cos \left ( dx+c \right ) +1}}}{\it EllipticF} \left ({\frac{i \left ( -1+\cos \left ( dx+c \right ) \right ) }{\sin \left ( dx+c \right ) }},i \right ) \sin \left ( dx+c \right ) +iB{\it EllipticE} \left ({\frac{i \left ( -1+\cos \left ( dx+c \right ) \right ) }{\sin \left ( dx+c \right ) }},i \right ) \cos \left ( dx+c \right ) \sqrt{ \left ( \cos \left ( dx+c \right ) +1 \right ) ^{-1}}\sqrt{{\frac{\cos \left ( dx+c \right ) }{\cos \left ( dx+c \right ) +1}}}\sin \left ( dx+c \right ) +iA\sqrt{ \left ( \cos \left ( dx+c \right ) +1 \right ) ^{-1}}\sqrt{{\frac{\cos \left ( dx+c \right ) }{\cos \left ( dx+c \right ) +1}}}{\it EllipticF} \left ({\frac{i \left ( -1+\cos \left ( dx+c \right ) \right ) }{\sin \left ( dx+c \right ) }},i \right ) \sin \left ( dx+c \right ) -iB\sqrt{ \left ( \cos \left ( dx+c \right ) +1 \right ) ^{-1}}\sqrt{{\frac{\cos \left ( dx+c \right ) }{\cos \left ( dx+c \right ) +1}}}{\it EllipticF} \left ({\frac{i \left ( -1+\cos \left ( dx+c \right ) \right ) }{\sin \left ( dx+c \right ) }},i \right ) \sin \left ( dx+c \right ) +iB{\it EllipticE} \left ({\frac{i \left ( -1+\cos \left ( dx+c \right ) \right ) }{\sin \left ( dx+c \right ) }},i \right ) \sqrt{ \left ( \cos \left ( dx+c \right ) +1 \right ) ^{-1}}\sqrt{{\frac{\cos \left ( dx+c \right ) }{\cos \left ( dx+c \right ) +1}}}\sin \left ( dx+c \right ) -B\cos \left ( dx+c \right ) +B \right ) } \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F] time = 0., size = 0, normalized size = 0. \begin{align*} \int{\left (B \sec \left (d x + c\right ) + A\right )} \sqrt{b \sec \left (d x + c\right )}\,{d x} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [F] time = 0., size = 0, normalized size = 0. \begin{align*}{\rm integral}\left ({\left (B \sec \left (d x + c\right ) + A\right )} \sqrt{b \sec \left (d x + c\right )}, x\right ) \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F] time = 0., size = 0, normalized size = 0. \begin{align*} \int \sqrt{b \sec{\left (c + d x \right )}} \left (A + B \sec{\left (c + d x \right )}\right )\, dx \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F] time = 0., size = 0, normalized size = 0. \begin{align*} \int{\left (B \sec \left (d x + c\right ) + A\right )} \sqrt{b \sec \left (d x + c\right )}\,{d x} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]